diff options
| author | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-07-07 01:43:36 +0000 |
|---|---|---|
| committer | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-07-07 01:43:36 +0000 |
| commit | fbb3b7f05737f9571b04b0a8f4f15c0928de8545 (patch) | |
| tree | 343247117a7587b8ef5c418c9528d1cf2e0b6f1c /app/[lng]/evcp/(evcp)/report/page.tsx | |
| parent | 9945ad119686a4c3a66f7b57782750f78a366cfb (diff) | |
(대표님) 변경사항 20250707 10시 43분
Diffstat (limited to 'app/[lng]/evcp/(evcp)/report/page.tsx')
| -rw-r--r-- | app/[lng]/evcp/(evcp)/report/page.tsx | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/app/[lng]/evcp/(evcp)/report/page.tsx b/app/[lng]/evcp/(evcp)/report/page.tsx index 95566b05..f84ebe52 100644 --- a/app/[lng]/evcp/(evcp)/report/page.tsx +++ b/app/[lng]/evcp/(evcp)/report/page.tsx @@ -1,26 +1,22 @@ - // app/procurement/dashboard/page.tsx import * as React from "react"; import { Skeleton } from "@/components/ui/skeleton"; import { Shell } from "@/components/shell"; import { ErrorBoundary } from "@/components/error-boundary"; -import { getDashboardData } from "@/lib/dashboard/service"; +import { getDashboardData, refreshDashboardData } from "@/lib/dashboard/service"; import { DashboardClient } from "@/lib/dashboard/dashboard-client"; +export const dynamic = 'force-dynamic'; // ① 동적 페이지 선언 + // 대시보드 데이터 로딩 컴포넌트 async function DashboardContent() { try { const data = await getDashboardData("evcp"); - - const handleRefresh = async () => { - "use server"; - return await getDashboardData("evcp"); - }; return ( <DashboardClient initialData={data} - onRefresh={handleRefresh} + onRefresh={refreshDashboardData} /> ); } catch (error) { @@ -119,9 +115,11 @@ function DashboardError({ error, reset }: { error: Error; reset: () => void }) { export default async function DashboardPage() { return ( <Shell className="gap-6"> + <ErrorBoundary fallback={DashboardError}> <React.Suspense fallback={<DashboardSkeleton />}> <DashboardContent /> </React.Suspense> + </ErrorBoundary> </Shell> ); -} +}
\ No newline at end of file |
